package com.sparrow.source.common.enums;

import java.util.Arrays;
import java.util.stream.Collectors;

/**
 * @author bryceyung
 * @since 2024/12/11
 */
public enum ChannelEnums {

    /**
     * 通道枚举
     */
    CHANNEL_1("1001", "国内安检通道01", 2),

    CHANNEL_2("1002", "国内安检通道02", 2),

    CHANNEL_3("1003", "国内安检通道03", 2),

    CHANNEL_4("1004", "国内安检通道04", 2),

    CHANNEL_5("1005", "国内安检通道05", 2),

    CHANNEL_6("1006", "国内安检通道06", 2),

    CHANNEL_7("1007", "国内安检通道07", 2),

    CHANNEL_8("1008", "国内安检通道08", 2),

    CHANNEL_9("1009", "国内安检通道10", 2),
    CHANNEL_10("1010", "国内安检通道11", 2),
    CHANNEL_11("1011", "国内安检通道12", 2),
    CHANNEL_12("1012", "国内安检通道14", 2),
    CHANNEL_13("1013", "国内安检通道15", 2),
    CHANNEL_14("1014", "国内安检通道16", 2),
    CHANNEL_15("1015", "国内安检通道17", 2),
    CHANNEL_16("1016", "国内安检通道18", 2),
    CHANNEL_17("1017", "安检预检查", 2),
    CHANNEL_18("1018", "安检分控室", 2),
    CHANNEL_19("1019", "1号安检休息通道", 1),
    CHANNEL_20("1020", "18号安检验证柜台", 1),
    CHANNEL_21("1021", "国际安检通道01", 2),
    CHANNEL_22("1022", "国际安检通道02", 2),
    CHANNEL_23("1023", "国际安检通道03", 2),
    CHANNEL_24("1024", "8米CIP安检通道19", 2),
    CHANNEL_25("1025", "8米CIP安检通道20", 2),
    CHANNEL_26("1026", "0米CIP安检通道", 2),
    CHANNEL_27("1027", "0米VIP安检通道", 2),
    CHANNEL_28("1028", "0米VIP安检休息室", 1),
    CHANNEL_29("1029", "0米国际中转", 2),

    CHANNEL_TEST_1("1050", "测试01", 2),
    CHANNEL_TEST_2("1051", "测试02", 2),
    CHANNEL_TEST_3("1052", "上班打卡通道", 1);

    private String channel;

    private String channelName;

    private Integer type;

    public String getChannel() {
        return channel;
    }

    public String getChannelName(){
        return channelName;
    }

    ChannelEnums(String channel, String channelName, Integer type) {
        this.channel = channel;
        this.channelName = channelName;
        this.type = type;
    }

    public static ChannelEnums getByChannel(String channel) {
        return Arrays.stream(ChannelEnums.values()).filter(c -> c.getChannel().equals(channel)).collect(Collectors.toList()).get(0);
    }

}
